package com.ruoyi.web.feign;

import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.*;

import java.util.Map;

@FeignClient(name = "demo", url = "http://localhost:8888")
public interface FeginDemo {

    @PostMapping("login")
    String login(@RequestBody Map<String, Object> body, @RequestHeader("Remote-Invoke") Boolean remoteInvoke);

    @GetMapping("system/user/{userId}")
    Map<String, Object> userGetInfo(@PathVariable("userId") Integer userId, @RequestHeader("Authorization") String token);
}
